﻿using HlELock.Core.Events;
using HlELock.Core.Models;
using HlELock.Core;
using Prism.Commands;
using Prism.Mvvm;
using Prism.Regions;
using System;
using System.Collections.Generic;
using System.Linq;

namespace HlELock.Modules.Hotel.Main.ViewModels
{
    public class CardInfoUserControlViewModel : BindableBase, INavigationAware
    {
        public CardInfoUserControlViewModel()
        {
        }
        public bool IsNavigationTarget(NavigationContext navigationContext)
            => true;

        public void OnNavigatedFrom(NavigationContext navigationContext)
        {

        }
        private CardDetailInfo _cardDetailInfo;
        public CardDetailInfo CurrentCard
        {
            get { return _cardDetailInfo; }
            set { SetProperty(ref _cardDetailInfo, value); }
        }
        public void OnNavigatedTo(NavigationContext navigationContext)
        {
            CurrentCard = navigationContext.Parameters.GetValue<CardDetailInfo>(nameof(CardDetailInfo));
        }
    }
}
